/**
 * 项目状态枚举
 */
export enum ProjectStatus {
  PLANNING = 'PLANNING',
  ACTIVE = 'ACTIVE',
  PAUSED = 'PAUSED',
  COMPLETED = 'COMPLETED',
  ARCHIVED = 'ARCHIVED'
}

/**
 * 项目优先级枚举
 */
export enum ProjectPriority {
  LOW = 'LOW',
  MEDIUM = 'MEDIUM',
  HIGH = 'HIGH',
  URGENT = 'URGENT'
}

/**
 * 项目实体
 */
export interface Project {
  id: number
  teamId: number
  name: string
  description?: string
  status: string
  priority: string
  startDate?: string
  endDate?: string
  progress: number
  projectManagerId?: number
  projectAvatarUrl?: string
  createdAt: string
  updatedAt: string
  
  // 前端扩展属性
  taskCount?: number
  announcementCount?: number
}

/**
 * 项目创建请求
 */
export interface ProjectCreateRequest {
  teamId: number
  name: string
  description?: string
  priority?: string
  startDate?: string
  endDate?: string
  projectManagerId?: number
}

/**
 * 项目更新请求
 */
export interface ProjectUpdateRequest {
  name: string
  description?: string
  priority?: string
  startDate?: string
  endDate?: string
  projectManagerId?: number
}

/**
 * 项目统计信息
 */
export interface ProjectStatistics {
  totalProjects: number
  activeProjects: number
  completedProjects: number
  overdueProjects: number
  averageProgress: number
}

/**
 * 任务状态枚举
 */
export enum TaskStatus {
  TODO = 'TODO',
  IN_PROGRESS = 'IN_PROGRESS',
  REVIEW = 'REVIEW',
  COMPLETED = 'COMPLETED',
  CANCELLED = 'CANCELLED'
}

/**
 * 任务优先级枚举
 */
export enum TaskPriority {
  LOW = 'LOW',
  MEDIUM = 'MEDIUM',
  HIGH = 'HIGH',
  URGENT = 'URGENT'
}

/**
 * 任务实体
 */
export interface Task {
  id: number
  projectId: number
  title: string
  description?: string
  status: string
  priority: string
  assigneeId?: number
  creatorId: number
  dueDate?: string
  completedAt?: string
  estimatedHours?: number
  actualHours?: number
  createdAt: string
  updatedAt: string
}

/**
 * 任务创建请求
 */
export interface TaskCreateRequest {
  projectId: number
  title: string
  description?: string
  priority?: string
  assigneeId?: number
  dueDate?: string
  estimatedHours?: number
}

/**
 * 任务更新请求
 */
export interface TaskUpdateRequest {
  title: string
  description?: string
  priority?: string
  assigneeId?: number
  dueDate?: string
  estimatedHours?: number
  actualHours?: number
}

/**
 * 任务统计信息
 */
export interface TaskStatistics {
  totalTasks: number
  todoTasks: number
  inProgressTasks: number
  completedTasks: number
  overdueTasks: number
}

/**
 * 公告实体
 */
export interface Announcement {
  id: number
  projectId: number
  title: string
  content: string
  creatorId: number
  isPinned: boolean
  createdAt: string
  updatedAt: string
}

/**
 * 公告创建请求
 */
export interface AnnouncementCreateRequest {
  projectId: number
  title: string
  content: string
  isPinned?: boolean
}

/**
 * 公告更新请求
 */
export interface AnnouncementUpdateRequest {
  title: string
  content: string
  isPinned?: boolean
}

/**
 * 公告统计信息
 */
export interface AnnouncementStatistics {
  totalAnnouncements: number
  pinnedAnnouncements: number
  todayAnnouncements: number
  weekAnnouncements: number
  monthAnnouncements: number
}
